{include file = $smarty.const.APPLICATION_PATH|cat:"/application/views/header.html"}
{literal}
<script type="text/javascript">
    $(function(){
        $('.search-tx span').click(function(){
            $(this).addClass('curr').siblings().removeClass('curr');
        });

        // 轮播
        var bullets = document.getElementById('scroll_position').getElementsByTagName('li');
        var slider = Swipe(document.getElementById('scroll_img'), {
            auto: 3000,
            continuous: true,
            callback: function(pos) {
                var i = bullets.length;
                while (i--) {
                    bullets[i].className = ' ';
                }
                bullets[pos].className = 'on';
            }
        });


        var mySwiper6 = new Swiper('#swiper-container6',{
            slidesPerView : 2,
            onTap: function(){
                mySwiper7.slideTo( mySwiper6.clickedIndex)
            }
        })

        var mySwiper7 = new Swiper('#swiper-container7',{
            onSlideChangeStart: function(){
                $('#swiper-container6 .active-nav').removeClass('active-nav')
                var activeNav = $('#swiper-container6 .swiper-slide').eq(mySwiper7.activeIndex).addClass('active-nav');
            }

        })

        var mySwiper2 = new Swiper('#swiper-container2',{
            slidesPerView : 2,
            onTap: function(){
                mySwiper3.slideTo( mySwiper2.clickedIndex)
            }
        })

        var mySwiper3 = new Swiper('#swiper-container3',{
            onSlideChangeStart: function(){
                $('#swiper-container2 .active-nav').removeClass('active-nav')
                var activeNav = $('#swiper-container2 .swiper-slide').eq(mySwiper3.activeIndex).addClass('active-nav');
            }

        })

        $(function(){
            $('.stm1 tr').not(":first").click(function(){
                window.location.href=$(this).attr('href');
            });
        });

        $(function(){
            $('.stm2 tr').not(":first").click(function(){

                window.location.href=$(this).attr('href');
            });
        });

         $(function(){
            $('.stm3 tr').not(":first").click(function(){
                window.location.href=$(this).attr('href');
            });
        });

        $(function(){
            $('.stm4 tr').not(":first").click(function(){
                window.location.href=$(this).attr('href');
            });
        });


        var mySwiper4 = new Swiper('#swiper-container4',{
            slidesPerView : 2,
            onTap: function(){
                mySwiper5.slideTo( mySwiper4.clickedIndex)
            }
        })

        var mySwiper5 = new Swiper('#swiper-container5',{
            onSlideChangeStart: function(){
                $('#swiper-container4 .active-nav').removeClass('active-nav')
                var activeNav = $('#swiper-container4 .swiper-slide').eq(mySwiper5.activeIndex).addClass('active-nav');
            }

        })




        /* 搜索按钮 */
        $('.search-btn').click(function(){
            var keyword = $('.search-text').val();
            var tag_val =  $('.search-tx>.curr').attr("v");

            if($('.search-text').val() == '') return;
            if(!$.trim($('.search-text').val())) {
                return;
            }
            searchKD(tag_val,keyword);
        });

        function searchKD(tag_val,keyword)
        {
            if(tag_val == 1){
                var url = "/search/index/keyword/"+keyword;
            }
            if(tag_val == 2){
                var url ="/buy/index/keyword/"+keyword
            }
            if(tag_val == 3){
                var url ="/supply/index/keyword/"+keyword
            }
            window.location = url;
        }



    });
</script>
{/literal}



<div class="wp_fixed">
<!--header stop-->
<header class="header">
    <article class="slider">
        <!--scroll-->
        <div class="scroll relative">
            <div class="scroll_box" id="scroll_img">
                <ul class="scroll_wrap">
                    <li><a href="/event/sample"><img src="../images/banner3.jpg" width="100%" /></a></li>
                    <li><a href="#"><img src="../images/banner2.jpg" width="100%" /></a></li>
                </ul>
            </div>
            <ul class="scroll_position" id='scroll_position'>
                <li class="on"><a href="javascript:void(0);"></a></li>
                <li><a href="javascript:void(0);"></a></li>
            </ul>
        </div>
        <!--scroll-->
    </article>

    <div class="search">
        <p class="search-tx"><span class="curr" v="1">现货</span><span v="2">求购</span></p>
        <p class="search-input"><input class="search-text" placeholder="输入商品名称" type="text"/><input class="search-btn" type="button" value=""/></p>
    </div>
</header>
<!--header end-->

<!--content stop-->
<nav class="category">
    <ul>
        <li>
            <a href="/entrust/setpone">
                <span class="menu1-icon micon"><i></i></span>
                <span class="cate-name">货主委托</span>
            </a>
        </li>

        <li>
            <a href="/entrust">
                <span class="menu2-icon micon"><i></i></span>
                <span class="cate-name">快捷求购</span>
            </a>
        </li>

        <li>
            <a href="/event/sample">
                <span class="menu3-icon micon"><i></i></span>
                <span class="cate-name">免费试样</span>
            </a>
        </li>
    </ul>
</nav>



<div class="nav-h3">
    <h3 class="ac-f"><span class="mp0"></span><i class="cp0">自营现货</i>

        <div class="nav-h3-wrap">
            <div style="width:140px;"id="swiper-container2" class="swiper-container">
                <div class="swiper-wrapper nav-h3-list an0">
                    <div class="swiper-slide active-nav">人民币</div>
                    <div class="swiper-slide">美金</div>
                </div>
            </div>
        </div>

    </h3>
</div>

<section class="hot-commodity">
    <div style="width:100%;" id="swiper-container3" class="swiper-container">
        <div class="swiper-wrapper">
            <div class="swiper-slide">
                <table class="ssw_tab stm1">
                    <tr>
                        <th>牌号</th>
                        <th>厂商</th>
                        <th>单价</th>
                        <th>更新时间</th>
                        <th></th>
                    </tr>
                    {foreach from=$price.RMB key=key item=item}
                    <tr href="/price/detail/id/{$item.id}">
                        <td width="60"><p class="ptm1">{$item.product_name}</p></td>
                        <td>{$item.brand_name}</td>
                        <td class="orange">{$item.currency_mark}{$item.price}</td>
                        <td>{$item.create_time}</td>
                        <td><img src="/images/icons5.png" width="50%"/></td>
                    </tr>
                    {/foreach}
                </table>
            </div>

            <div class="swiper-slide">
                <table class="ssw_tab stm2">
                    <tr>
                        <th>牌号</th>
                        <th>厂商</th>
                        <th>单价</th>
                        <th>更新时间</th>
                        <th></th>
                    </tr>
                    {foreach from=$price.USD key=key item=item}
                    <tr href="/price/detail/id/{$item.id}">
                        <td width="60"><p class="ptm1">{$item.product_name}</p></td>
                        <td>{$item.brand_name}</td>
                        <td class="orange">{$item.currency_mark}{$item.price}</td>
                        <td>{$item.create_time}</td>
                        <td><img src="/images/icons5.png" width="50%"/></td>
                    </tr>
                    {/foreach}
                </table>
            </div>
        </div>
    </div>

</section>


<div class="mt10p"><a href="/entrust/setpone"><img src="/images/b1.jpg"  class="fl" width="100%"/></a></div>


<div class="nav-h3">
    <h3 class="ac-f"><span class="mp1"></span><i class="cp1">求购信息</i>

        <!--<div class="nav-h3-wrap">-->
            <!--<div style="width:140px;"id="swiper-container4" class="swiper-container">-->
                <!--<div class="swiper-wrapper nav-h3-list an1">-->
                    <!--<div class="swiper-slide active-nav">人民币</div>-->
                    <!--<div class="swiper-slide">美金</div>-->
                <!--</div>-->
            <!--</div>-->
        <!--</div>-->

    </h3>
</div>
<section class="hot-commodity">


    <div style="width:100%;" id="swiper-container5" class="swiper-container">
        <div class="swiper-wrapper">
            <div class="swiper-slide">
                <table class="ssw_tab stm3">
                    <tr>
                        <th>牌号</th>
                        <th>厂商</th>
                        <th>单价</th>
                        <th>更新时间</th>
                        <th></th>
                    </tr>
                    {foreach from=$buylist key=key item=item}
                    <tr href="/buy/detail/id/{$item.id}">
                        <td width="60"><p class="ptm1">{$item.product_name}</p></td>
                        <td>{$item.brand_name}</td>
                        <td class="orange">￥{$item.price}</td>
                        <td>{$item.update_time}</td>
                        <td><img src="/images/icons5.png" width="50%"/></td>
                    </tr>
                    {/foreach}


                </table>
            </div>

        </div>
    </div>

</section>

<div class="mt10p"><a href="/entrust/index"><img src="/images/b2.jpg"  class="fl" width="100%"/></a></div>





<div class="nav-h3">
    <h3 class="ac-f"><span class="mp2"></span><i class="cp2">市场报价</i>

        <!--<div class="nav-h3-wrap">-->
            <!--<div style="width:140px;"id="swiper-container6" class="swiper-container">-->
                <!--<div class="swiper-wrapper nav-h3-list an2">-->
                    <!--<div class="swiper-slide active-nav">人民币</div>-->
                    <!--<div class="swiper-slide">美金</div>-->
                <!--</div>-->
            <!--</div>-->
        <!--</div>-->

    </h3>
</div>
<section class="hot-commodity">


    <div style="width:100%;" id="swiper-container7" class="swiper-container">
        <div class="swiper-wrapper">
            <div class="swiper-slide">
                <table class="ssw_tab stm4">
                    <tr>
                        <th>公司名称</th>
                        <th>联系人</th>
                        <th>电话</th>
                        <th>更新时间</th>
                        <th></th>
                    </tr>
                    {foreach from=$supplylist key=key item=item}
                    <tr href="/supply/shoplist/id/{$item.id}">
                        <td><span class="ptm2">{$item.business_remarks}</span></td>
                        <td>{$item.contacts}</td>
                        <td class="orange">{$item.mobile}</td>
                        <td>{$item.update_time}</td>
                        <td><img src="/images/icons5.png" width="50%"/></td>
                    </tr>
                    {/foreach}


                </table>
            </div>

        </div>
    </div>

</section>
<div style="height: 10px;"></div>
</div>
{include file = $smarty.const.APPLICATION_PATH|cat:"/application/views/common/footerlogin.html"}

{include file = $smarty.const.APPLICATION_PATH|cat:"/application/views/footer.html"}
